import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {CustomerListComponent} from './customer-list/customer-list.component';
import {AuthGuard} from '../shared/auth.guard';
import {CustomerDetailComponent} from './customer-detail/customer-detail.component';

const routes: Routes = [
  // {path: '', component: CustomerListComponent, canActivate: [AuthGuard]}
  {path: '', component: CustomerListComponent,  canActivate: [AuthGuard]},
  {path: ':id', component: CustomerDetailComponent,  canActivate: [AuthGuard]}
];

@NgModule({
  imports: [
    RouterModule.forChild(routes)
  ]
})

export class CustomersRoutingModule {}
